// server.js

var express = require('express');
var app = express();
var bodyParser = require('body-parser');


var urlencodedParser = bodyParser.urlencoded({extended:false})

app.use(express.static('public'));
app.use(express.static('src'));

app.get('/',function(req,res){
	res.sendFile(__dirname+"/src/"+"index.html");
})

/*app.post('/process_get',urlencodedParser,function(req,res){
	response ={
		first_name:req.body.first_name,
		last_name:req.body.last_name
	}
	console.log(response)
	res.end(JSON.stringify(response));
})
*/


var server = app.listen(5000,function(){
	var host = server.address().address
	var port = server.address().port
	console.log(host,port)
})